﻿<Application x:Class="Microsoft.Coding4Fun.TweetCraft.Tray.TweetCraftApplication"
    xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
    xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
    xmlns:wf="clr-namespace:System.Windows.Forms;assembly=System.Windows.Forms"
    xmlns:tr="clr-namespace:Microsoft.Coding4Fun.TweetCraft.Tray">
    <Application.Resources>
        <ResourceDictionary>
            <ResourceDictionary.MergedDictionaries>
                <!-- Merge the World of Warcraft styles -->
                <ResourceDictionary Source="WowStyleDictionary.xaml" />
            </ResourceDictionary.MergedDictionaries>

            <!-- ContextMenu for the notification area icon -->
            <wf:ContextMenuStrip x:Key="TweetCraftContextMenuStrip">
                <wf:ContextMenuStrip.Items>
                    <wf:ToolStripMenuItem Name="twitterStatusMenuItem" Text="{x:Static tr:Strings.TwitterStatusUnknownText}" Enabled="False" />
                    <wf:ToolStripSeparator />
                    <wf:ToolStripMenuItem Name="openTwitterMenuItem" Text="{x:Static tr:Strings.OpenTwitterMenuItemText}" Click="OnOpenTwitterClicked" />
                    <wf:ToolStripMenuItem Name="launchWowMenuItem" Text="{x:Static tr:Strings.LaunchWowMenuItemText}" Click="OnLaunchWowClicked" />
                    <wf:ToolStripSeparator />
                    <wf:ToolStripMenuItem Name="settingsMenuItem" Text="{x:Static tr:Strings.SettingsMenuItemText}" Click="OnSettingsClicked" />
                    <wf:ToolStripMenuItem Name="showNotificationsMenuItem" Text="{x:Static tr:Strings.ShowNotificationsMenuItemText}"
                                      CheckOnClick="True" CheckedChanged="OnShowNotificationsChanged" />
                    <wf:ToolStripMenuItem Name="runOnStartupMenuItem" Text="{x:Static tr:Strings.RunOnStartupMenuItemText}"
                                      CheckOnClick="True" CheckedChanged="OnStartWithWindowsChanged" />
                    <wf:ToolStripSeparator />
                    <wf:ToolStripMenuItem Name="exitMenuItem" Text="{x:Static tr:Strings.ExitMenuItemText}" Click="OnExitClicked" />
                </wf:ContextMenuStrip.Items>
            </wf:ContextMenuStrip>
            
            <!-- The actual notification area icon for TweetCraft -->
            <wf:NotifyIcon x:Key="TweetCraftNotifyIcon" 
                       ContextMenuStrip="{StaticResource TweetCraftContextMenuStrip}"
                       Text="{x:Static tr:Strings.TweetCraftTooltip}"
                       Icon="{x:Static tr:Icons.TweetCraft}"
                       DoubleClick="OnSettingsClicked">
            </wf:NotifyIcon>
        </ResourceDictionary>
    </Application.Resources>
</Application>
